<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>动态绑定 style ——对象语法</title>
    <script src="../../../../../js/vue.global.js"></script>
</head>
<body>
<div id="app">
    <h1 style="color: red; text-decoration: underline">Hello, World!</h1>
    <h1 v-bind:style="{color: colordecorate, textDecoration: textdecorate}">Hello, World!</h1>
    <h1 v-bind:style="abc">Hello, World!</h1>
</div>
<script>
    const app = Vue.createApp({
        data() {
            return {
                colordecorate: "red",
                textdecorate:"underline",

                abc: {
                    color: "red",
                    textDecoration: "underline",
                }
            }
        }
    })

    app.mount("#app")

</script>
</body>
</html>